#ifndef ABSTRACTPARSER_H
#define ABSTRACTPARSER_H

#include <QObject>


class AbstractEvent;
class AbstractParser : public QObject
{
    Q_OBJECT
public:
    enum Type {
        MessageType,
        OnlineStatusType,
        RecentContactType,
        CreateGroupType,
        Unknown
    };

public:
    explicit AbstractParser(QObject *parent = 0);

public:
    virtual Type type() const = 0;
    virtual AbstractEvent *parse(const QString &commandId, const QVariant &data) = 0;
};

#endif // ABSTRACTPARSER_H
